import { Component, OnInit } from '@angular/core';
import { ReadService } from "./read.service";
@Component({
  selector: 'app-read',
  templateUrl: './read.component.html',
  styleUrls: ['./read.component.scss'],
  providers: [ReadService]
})
export class ReadComponent implements OnInit {
  public readInfo: any = {
    sContent:''
  };
  constructor(
    public readService: ReadService
  ) { }

  ngOnInit() {
    this.getReadInfo();
  }
  // 获取阅读须知信息
  getReadInfo() {
    let that = this;
    this.readService.getReadInfo().subscribe(data => {
      if (data) {
        that.readInfo = data;
      }
    })
  }
}
